

#include <public/prac62_iface_v1.h>





	// ******************* CONSTRUCTOR ************************************



prac62::prac62(const char * const roomname,TEDROOMComponentID id, TEDROOMUInt32 roomNumMaxMens, TEDROOMPriority roomtaskPrio, TEDROOMStackSizeType roomStack, CEDROOMMemory *pActorMemory ) : 

		CEDROOMComponent(roomname,id,EDROOMprioMINIMUM+1,8,roomNumMaxMens,roomtaskPrio,roomStack, pActorMemory )



		// ***************	Estado Top *****************

		,edroomTopState(*this)


{


}


	//***************	METODOS PUBLICOS  ********************************



		//**********           CONFIGURACION               ************


int prac62::EDROOMConfig() {




 return 0; }



		//**********           START               ************


int prac62::EDROOMStart() {



		//****************** Component Start **********************

	CEDROOMComponent::EDROOMStart(); 	// Llamada a la funcion Start de la clase Actor

return 0;}


	// ***************	PROTECTED METHODS *******************************



		//**********        BEHAVIOUR          ************



void prac62::EDROOMBehaviour() {

	edroomTopState.EDROOMInicio();
	edroomTopState.EDROOMBehaviour();

}




		//**********        ComponentIsFinished           ************


	#ifdef _EDROOM_SYSTEM_CLOSE

TEDROOMBool prac62::EDROOMIsComponentFinished() {


	return ( Client1.EDROOMIsComponentFinished() && Client2.EDROOMIsComponentFinished() && Client3.EDROOMIsComponentFinished() && Client4.EDROOMIsComponentFinished() && SuperServer.EDROOMIsComponentFinished() && Client5.EDROOMIsComponentFinished() && Client6.EDROOMIsComponentFinished() && Client7.EDROOMIsComponentFinished() && Client8.EDROOMIsComponentFinished() && CEDROOMComponent::EDROOMIsComponentFinished());

}


	#endif

	// ***************	EDROOM Memory ******************************

void prac62::CEDROOMMemory::SetMemory(TEDROOMUInt32 numMessages_, CEDROOMMessage * MessagesMem_, TEDROOMBool * MessagesMemMarks_, CEDROOMQueue::CQueueNode * QueueNodesMem_, TEDROOMBool * QueueNodesMemMarks_){
		CEDROOMComponentMemory::SetMemory( numMessages_,MessagesMem_, MessagesMemMarks_, QueueNodesMem_, QueueNodesMemMarks_, QueueHeads);


}

